#ifndef __ERROR_COMMON_H__
#define __ERROR_COMMON_H__

namespace ErrorHandling {

typedef time_t			ErrorTimeStamp;
typedef unsigned int	ErrorSeverity;
typedef unsigned int	ErrorId;

const ErrorId       EID_NULL = 0;
const ErrorId       EID_FOUNDATION_BASE = 0;			 // starting error id for SpiFundation
const ErrorId       EID_CONTROL_BASE = 10000;			 // starting error id for SpiFundation
const ErrorId       EID_Legacy_BASE = 30000;			 // starting error id for SpiFundation

const ErrorSeverity ESEVunknown = 0;             // error source is undetermined, continuing anyway
const ErrorSeverity ESEVsoftwareWarning = 1;     // automatically recovered, but may indicate some underlying software issue
const ErrorSeverity ESEVhardwareWarning = 2;     // automatically recovered, but may indicate some underlying hardware issue
const ErrorSeverity ESEVsoftwareRecoverable = 3; // can be recovered by fixing software issue and retrying
const ErrorSeverity ESEVhardwareRecoverable = 4; // can be recovered by fixing hardware issue and retrying
const ErrorSeverity ESEVfatal = 5;               // cannot be recovered from - notify service

// 
// function : severityName
//
// returns : a string literal
//
// description : this is a static function for translating from ErrorSeverity
//               to a string.
//               
const char* severityName( ErrorSeverity sev );

} // end namespace ErrorHandling

#endif // __ERROR_COMMON_H__
